char arr[] = { 'a','e','i','o','u' };
class Solution {
public:

    bool findtrue(char c)
    {
        for (int i = 0; i < 5; i++)
        {
            if (c == arr[i] || c == arr[i] - 32)
                return true;
        }
        return false;
    }
    bool halvesAreAlike(string s) {

        int count = 0;
        int len = s.size();
        for (int i = 0; i < len; i++)
        {
            if (findtrue(s[i]))
            {
                if (i < len / 2)
                    count++;
                else
                    count--;
            }
        }
        return count == 0;
    }
};
